package com.schoolai.feign.ai;

import com.schoolai.util.base.Result;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import reactor.core.publisher.Flux;

/**
 * Copyright(C),2019-2025，XX公司
 * FileName:IFeignDietaryRequirementsController
 * Author:bobby
 * 创建时间：2025/9/25 15:53
 * Description:餐饮AI推荐服务调用提供方
 * History:
 * <auth>        <time>       <version>       <desc>
 * 作者          修改时间       版本号         描述
 */
@FeignClient(value="ai-service", path = "/ai")
@Tag(name = "AI接口", description = "AI接口")
public interface IFeignAIController {
    @Operation(summary = "学生午餐AI推荐")
    @GetMapping("/api/feign/lunchRecommendation")
    public String lunchRecommendation();

    @Operation(summary = "学生午餐AI推荐以stream形式输出")
    @GetMapping("/api/feign/lunchRecommendationByStream")
    public Flux<String> lunchRecommendationByStream();

    @Operation(summary = "AI模型字符转语音")
    @GetMapping("/api/feign/ttsAI")
    public Result ttsAI();

    @Operation(summary = "AI模型通过新单词生成文章")
    @GetMapping("/api/feign/createArticleByNewWorks/{id}")
    public Result createArticleByNewWorks(@Parameter(description = "任务ID", required = true, example = "1")
                                              @PathVariable("id") String id);
}
